﻿namespace 超市系统
{
    internal class Commodity
    {
        //商品属性：价格，数量，编号
        private int _price;

        private string _name;
        private string _id;
        private Companys _company;

        public enum Companys
        {
            KG,
            ML,
            台
        }

        public int Price { get => _price; set => _price = value; }
        public string Id { get => _id; set => _id = value; }
        public string Name { get => _name; set => _name = value; }
        public Companys Company { get => _company; set => _company = value; }

        public Commodity(string id, int price, string name, Companys company)
        {
            Price = price;
            Id = id;
            Name = name;
            Company = Company;
        }
    }
}